
package com.chengyu.eyc.model;

import java.io.Serializable;

import javax.persistence.Column;
import javax.persistence.Id;
import javax.persistence.Table;

import com.chengyu.eyc.utils.EycGenId;

import tk.mybatis.mapper.annotation.KeySql;

@Table(name = "eyc_user")
public class EycUser extends BaseModel implements Serializable {

    private static final long serialVersionUID = 1L;

    @KeySql(genId = EycGenId.class)
    @Id
    @Column(name = "EYC_USER_ID")
    private String eycUserId;

    /**
     * USERID
     */
    @Column(name = "USER_ID")
    private String userId;

    /**
     * OPENID
     */
    @Column(name = "OPENID")
    private String openid;

    /**
     * 昵称
     */
    @Column(name = "NICK_NAME")
    private String nickName;

    /**
     * 头像
     */
    @Column(name = "AVATAR_URL")
    private String avatarUrl;

    /**
     * 推荐人
     */
    @Column(name = "REFERRER")
    private String referrer;

    /**
     * 手机号
     */
    @Column(name = "PHONE_NUMBER")
    private String phoneNumber;


    /**
     * 0:未知,1:男性,2:女性
     */
    @Column(name = "GENDER")
    private String gender;

    /**
     * 客户等级
     */
    @Column(name = "GRAND")
    private String grand;

    /**
     * 1-会员;0-非会员
     */
    @Column(name = "MEMBER")
    private Boolean member;

    @Column(name = "PASSWORD")
    private String password;

    /**
     * 用户类型
     */
    @Column(name = "USER_TYPE")
    private String userType;

    @Column(name = "REMARK")
    private String remark;
    
    /**
     * 是否有效
     */
    @Column(name = "IS_ACTIVE")
    private Boolean isActive;

    /**
     * 获取头像
     *
     * @return AVATAR_URL - 头像
     */
    public String getAvatarUrl() {
        return avatarUrl;
    }

    /**
     * @return EYC_USER_ID
     */
    public String getEycUserId() {
        return eycUserId;
    }

    /**
     * 获取0:未知,1:男性,2:女性
     *
     * @return GENDER - 0:未知,1:男性,2:女性
     */
    public String getGender() {
        return gender;
    }

    /**
     * 获取客户等级
     *
     * @return GRAND - 客户等级
     */
    public String getGrand() {
        return grand;
    }


    /**
     * 获取是否有效
     *
     * @return IS_ACTIVE - 是否有效
     */
    public Boolean getIsActive() {
        return isActive;
    }

    /**
     * 获取1-会员;0-非会员
     *
     * @return MEMBER - 1-会员;0-非会员
     */
    public Boolean getMember() {
        return member;
    }

    /**
     * 获取昵称
     *
     * @return NICK_NAME - 昵称
     */
    public String getNickName() {
        return nickName;
    }

    /**
     * 获取OPENID
     *
     * @return OPENID - OPENID
     */
    public String getOpenid() {
        return openid;
    }

    /**
     * @return PASSWORD
     */
    public String getPassword() {
        return password;
    }

    /**
     * 获取手机号
     *
     * @return PHONE_NUMBER - 手机号
     */
    public String getPhoneNumber() {
        return phoneNumber;
    }

    /**
     * 获取推荐人
     *
     * @return REFERRER - 推荐人
     */
    public String getReferrer() {
        return referrer;
    }

    /**
     * @return REMARK
     */
    public String getRemark() {
        return remark;
    }

    /**
     * 获取USERID
     *
     * @return USER_ID - USERID
     */
    public String getUserId() {
        return userId;
    }

    /**
     * 获取用户类型
     *
     * @return USER_TYPE - 用户类型
     */
    public String getUserType() {
        return userType;
    }

    /**
     * 设置头像
     *
     * @param avatarUrl 头像
     */
    public void setAvatarUrl(String avatarUrl) {
        this.avatarUrl = avatarUrl == null ? null : avatarUrl.trim();
    }

    /**
     * @param eycUserId
     */
    public void setEycUserId(String eycUserId) {
        this.eycUserId = eycUserId == null ? null : eycUserId.trim();
    }

    /**
     * 设置0:未知,1:男性,2:女性
     *
     * @param gender 0:未知,1:男性,2:女性
     */
    public void setGender(String gender) {
        this.gender = gender == null ? null : gender.trim();
    }

    
    /**
     * 设置客户等级
     *
     * @param grand 客户等级
     */
    public void setGrand(String grand) {
        this.grand = grand == null ? null : grand.trim();
    }

    /**
     * 设置是否有效
     *
     * @param isActive 是否有效
     */
    public void setIsActive(Boolean isActive) {
        this.isActive = isActive;
    }

    /**
     * 设置1-会员;0-非会员
     *
     * @param member 1-会员;0-非会员
     */
    public void setMember(Boolean member) {
        this.member = member;
    }

    /**
     * 设置昵称
     *
     * @param nickName 昵称
     */
    public void setNickName(String nickName) {
        this.nickName = nickName == null ? null : nickName.trim();
    }

    /**
     * 设置OPENID
     *
     * @param openid OPENID
     */
    public void setOpenid(String openid) {
        this.openid = openid == null ? null : openid.trim();
    }

    /**
     * @param password
     */
    public void setPassword(String password) {
        this.password = password == null ? null : password.trim();
    }

    /**
     * 设置手机号
     *
     * @param phoneNumber 手机号
     */
    public void setPhoneNumber(String phoneNumber) {
        this.phoneNumber = phoneNumber == null ? null : phoneNumber.trim();
    }

    /**
     * 设置推荐人
     *
     * @param referrer 推荐人
     */
    public void setReferrer(String referrer) {
        this.referrer = referrer == null ? null : referrer.trim();
    }

    /**
     * @param remark
     */
    public void setRemark(String remark) {
        this.remark = remark == null ? null : remark.trim();
    }
    
    /**
     * 设置USERID
     *
     * @param userId USERID
     */
    public void setUserId(String userId) {
        this.userId = userId == null ? null : userId.trim();
    }

    /**
     * 设置用户类型
     *
     * @param userType 用户类型
     */
    public void setUserType(String userType) {
        this.userType = userType == null ? null : userType.trim();
    }


    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", eycUserId=").append(eycUserId);
        sb.append(", userId=").append(userId);
        sb.append(", openid=").append(openid);
        sb.append(", nickName=").append(nickName);
        sb.append(", avatarUrl=").append(avatarUrl);
        sb.append(", referrer=").append(referrer);
        sb.append(", phoneNumber=").append(phoneNumber);
        sb.append(", gender=").append(gender);
        sb.append(", grand=").append(grand);
        sb.append(", member=").append(member);
        sb.append(", password=").append(password);
        sb.append(", userType=").append(userType);
        sb.append(", remark=").append(remark);
        sb.append(", isActive=").append(isActive);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }

}